package app;

import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;

public class BankDate {

    public static void main(String[] args) {

	Date date = new Date();
	System.out.println(getNextBankDate(date));

    }

    static Date getNextBankDate(Date date) {
	GregorianCalendar calendar = new GregorianCalendar();
	
	calendar.setTime(date);

	int weekDay = calendar.get(Calendar.DAY_OF_WEEK);

	int nextBankDay = 1;
	if (weekDay == Calendar.SATURDAY) {
	    nextBankDay = 2;
	}
	if (weekDay == Calendar.FRIDAY) {
	    nextBankDay = 3;
	}
	calendar.add(Calendar.DAY_OF_YEAR, nextBankDay);
	date = calendar.getTime();

	return date;
    }
}
